package com.luckku.boot.service;

import com.luckku.boot.entity.User;
import com.baomidou.mybatisplus.extension.service.IService;

import java.util.Map;

/**
 * <p>
 *  服务类
 * </p>
 *
 * @author Luckku
 * @since 2022-10-09
 */
public interface UserService extends IService<User> {

    /**
     * 注册功能
     * @param user User
     * @return 注册对象
     */
    User executeRegister(User user);

    /**
     * 用户登录
     *
     * @param user User
     * @return 生成的JWT的token
     */
    Map<String,String> executeLogin(User user);

    /**
     * 获取用户信息
     *
     * @param account String
     * @return dbUser
     */
    User getUserById(String account);
}
